const g5Data = require('./data/5G.json');
const volteData = require('./data/volte.json');

let { headers, list } = g5Data;
list = [...list, ...volteData.list];
list.sort((a, b)=> {
  const dateA = new Date(a.k0);
  const dateB = new Date(b.k0);
  return dateB - dateA;
});

module.exports = [
  {
    url: '/vue-admin-template/logAudit/headers',
    type: 'get',
    response: config => {
      return {
        code: 20000,
        data: {
          total: headers.length,
          items: headers
        }
      }
    }
  },
  {
    url: '/vue-admin-template/logAudit/list',
    type: 'get',
    response: config => {
      return {
        code: 20000,
        data: {
          total: list.length,
          items: list
        }
      }
    }
  }
]
